#include <stdio.h>

int main(int argc, char const *argv[])
{
    int n;
    scanf("%d", &n);
    printf("%d\n", n / 3 * 2 + ((n % 3 > 1) ? 1 : 0));
    return 0;
}
